<template>
  <div id="app">
    <router-view route />
    <van-tabbar v-model="active" @change="tabbarHandleChange">
      <van-tabbar-item name="home" to="/" icon="home-o">首页</van-tabbar-item>
      <van-tabbar-item name="lesson" to="/lesson" icon="search">课程</van-tabbar-item>
      <van-tabbar-item name="profile" to="/profile" icon="setting-o">个人重心</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  name: 'App',
  data() {
    return {
      active: 'home'
    }
  },

  methods: {
    tabbarHandleChange(active) {
      console.log(active)
    }
  }
}
</script>

<style lang="scss">
* {
  box-sizing: border-box;
}
</style>
